load("//bzl:cpp_library.bzl", "cpp_library")

package(default_visibility = ["//visibility:public"])

cpp_library(
    name = "atomic_grow_array",
    hdrs = [
        "atomic_grow_array.h",
    ],
    deps = [
        "//folly:c_portability",
        "//folly:constexpr_math",
        "//folly:likely",
        "//folly:scope_guard",
        "//folly/container:span",
        "//folly/lang:align",
        "//folly/lang:bits",
        "//folly/lang:new",
    ],
)

cpp_library(
    name = "relaxed_concurrent_priority_queue",
    hdrs = [
        "RelaxedConcurrentPriorityQueue.h",
    ],
    deps = [
        "//folly:random",
        "//folly:spin_lock",
        "//folly:thread_local",
        "//folly/detail:futex",
        "//folly/lang:align",
        "//folly/synchronization:hazptr",
        "//folly/synchronization:wait_options",
        "//folly/synchronization/detail:spin",
    ],
)

cpp_library(
    name = "lock_free_ring_buffer",
    hdrs = ["LockFreeRingBuffer.h"],
    deps = [
        "//folly:portability",
        "//folly:traits",
        "//folly/detail:turn_sequencer",
        "//folly/portability:unistd",
        "//folly/synchronization:sanitize_thread",
        "@boost.utility",
    ],
)

cpp_library(
    name = "flat_combining_priority_queue",
    hdrs = ["FlatCombiningPriorityQueue.h"],
    deps = [
        "//folly:optional",
        "//folly/detail:futex",
        "//folly/synchronization:flat_combining",
        "@glog",
    ],
)

cpp_library(
    name = "single_writer_fixed_hash_map",
    hdrs = [
        "SingleWriterFixedHashMap.h",
    ],
    deps = [
        "//folly/lang:bits",
        "@glog",
    ],
)
